package com.jumper.property.comparer.core.formatter;


import com.jumper.property.comparer.core.constant.FormatConstant;

public class ObjectDisplayNameDiffFormatter extends AbstractDiffFormatter {

    private final String displayNames;

    public ObjectDisplayNameDiffFormatter(String displayNames) {
        this.displayNames = displayNames;
    }

    @Override
    public String format() {
        return pattern.getCompareObjectDisplayName()
                .replace(FormatConstant.UNION_PROPERTY_NAMES_KEY, displayNames);
    }
}
